Basic tutorial on using table alias and field alias in MySQL,
MySQL table Alias (Alias)SQL table aliasIn an SQL statement, you can specify an Alias (Alias) for the table name and field (column) name. The Alias is a standard SQL syntax and is
SQL Alias syntax
SELECT column_name (s) FROM table_name AS alias_name
Column SQL Alias syntax
SELECT column_name AS alias_name FROM table_name
Alias instance: use the table name Alias
Suppose we have two tables: "Persons" and "Product_Orders ". We
Select Column1+10 as c1,c1+10 as C2 from table1;Want to achieve the above effect, the result in MySQL inside error, the hint can not find C1 this column;-Different databases are not the sameIt is not generally supported to continue using aliases in
SELECT column_name (s) from table_name as Alias_name
SELECT column_name as Alias_name from table_name
Suppose we have two tables: "Persons" and "Product_orders" respectively. We assign them the alias "P" and "Po" respectively. Now, we want to
MySQL learning footprint record 14-table alias and self-join table used in this query: The following table num represents the bus route, such as 1 car, 2 car, stop with table parking site, such as Station A and Station B:
route;+------+------+| num
MySQL learning footprint record 14 -- table alias and self-linked bitsCN.com
MySQL learning footprint record 14-table alias and self-join
Tables used in this query:
The following table num represents A bus route, such as A 1-way vehicle, A 2-way
When writing SQL statements, some statement aliases cannot be called. Baidu's reasons are due to different alias mechanisms. In order to avoid making the same mistake again next time, I summarized the information found on the Internet. The execution
Mysql "Every derived table must have its own alias" error solution, derivedalias
Mysql Every derived table must have its own alias error Solution
Every derived table must have its own alias
This statement means that each derived table must have its
Mysql encounters an error similar to "Every derived table must have its own alias ".
Every derived table must have its own alias
This statement means that each derived table must have its own Alias.
This error occurs when multiple tables are queried.
18.2.1 MySQL server has gone away errors related to Lost connection to server during query.
The most common cause of the MySQL server has gone away error is that the server times out and closes the connection. By default, if nothing happens, the
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.